<template>
	<view>
		<view class="box_list">
			<view class="title">
				订单类型
			</view>
			<view class="icon_text_list">
				<view class="icon_text" v-for="(item,index) in orderList" :key="index" @click="gotoOrder({id:item.id,url:item.url})">
					<image class="image" :src="item.src" mode=""></image>
					<text class="text">{{item.name}}</text>
				</view>
				
			</view>

		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				orderList: [{
						id: 0,
						name: '婚宴信息',
						src:'../../static/orderImgs/weddingbanquet.png',
						url:'/pages/applyOrder/applyOrder'
					},
					{
						id: 1,
						name: '婚庆信息',
						src:'../../static/orderImgs/wedding.png',
						url:'/pages/applyOrder/applyOrder'
					},
					{
						id: 2,
						name: '一站式',
						src:'../../static/orderImgs/one-stop.png',
						url:'/pages/applyOrder/applyOrder'
					},
					{
						id: 3,
						name: '婚纱摄影',
						src:'../../static/orderImgs/weddingphoto.png',
						url:'/pages/applyOrder/applyOrder'
					},
					{
						id: 4,
						name: '婚车',
						src:'../../static/orderImgs/weddingCar.png',
						url:'/pages/applyOrder/applyOrder'
					},
					{
						id: 5,
						name: '婚纱礼服',
						src:'../../static/orderImgs/weddingdress.png',
						url:'/pages/applyOrder/applyOrder'
					},
					{
						id: 6,
						name: '男装',
						src:'../../static/orderImgs/tries.png',
						url:'/pages/applyOrder/applyOrder'
					},
					{
						id: 7,
						name: '宝宝宴',
						src:'../../static/orderImgs/babyFeast.png',
						url:'/pages/applyOrder/applyOrder'
					},
					{
						id: 8,
						name: '会务',
						src:'../../static/orderImgs/Conference.png',
						url:'/pages/applyOrder/applyOrder'
					},
					{
						id: 9,
						name: '珠宝',
						src:'../../static/orderImgs/jewellery.png',
						url:'/pages/applyOrder/applyOrder'
					},
					{
						id: 10,
						name: '喜糖',
						src:'../../static/orderImgs/weddingcandies.png',
						url:'/pages/applyOrder/applyOrder'
					},
					// {
					// 	id: 11,
					// 	name: '返佣单',
					// 	src:'../../static/orderImgs/fanyong.png',
					// 	url:'/pages/audit/clubOrder/clubOrder'
					// }
				],
				options:''
			};
		},
		onLoad(options) {
			this.options=options
		},
		methods:{
			gotoOrder(e){
				uni.navigateTo({
					url:`${e.url}?orderType=${e.id}&&earnestMoney=${this.options.earnestMoney?this.options.earnestMoney:''}&&id=${this.options.id}&&pid=${this.options.pid?this.options.pid:''}`
				})
				
			}
		}
	}
</script>

<style lang="less">
	page {
		background: #f4f4f4;
		padding: 0;
	}

	.box_list {
		width: 100%;
		height: 100%;
		padding: 30upx 0 30upx 0;
		box-sizing: border-box;

		.title {
			padding-left: 30upx;
			font-size: 28upx;
			color: #b8b8b8;
		}

		.icon_text_list {
			margin-top: 20upx;
			padding: 30upx;
			display: flex;
			justify-content: left;
			flex-wrap:wrap ;
			background-color: #fff;            
			.icon_text {
				margin-bottom: 50upx;
				width: calc(100%/5);
				display: flex;
				flex-direction: column;
				align-items: center;
				justify-content: space-around;				                 
				.image {
					width: 98upx;
					height: 98upx;					
				}
				.text {
					margin-top: 12upx;
					font-size: 28upx;					
				}
			}
		}
	}
</style>
